zipCheck checks a zipcode against a list of the 895 valid 3-digit zip areas in the 50 states (as of 1/88) and returns the correct state abbreviation for the target area.
© Copyright 1988 by Sam Thornton
May be copied & distributed without charge only, except for nominal copying and distribution costs. Not for commercial sale or resale.
Written in LightSpeed C 3.0, 9/6/88 - some portions © by Symantec and Apple.
For a copy of the C source code, send a blank disk and $1 for postage & handling to:
Sam Thornton
PO Box 123
Fairfield, NE 68938
ΓÇóΓÇóSam has helped the continuing production of the Developer Stack by sending in this contribution. Thanks, Sam!
[Editor]
-- part contents for background part 7
----- text -----
Syntax:
get zipCheck(<"zipcode">)
get zipCheck(<field "fieldname">)
The return is the correct state abbreviation for the entered zipcode or, in the case of an error, an empty string.
The zipcode's format must be either 5 TEXT characters (e.g., "68938"), or 10 TEXT characters (e.g., "68938-0123").
If there is either a format error in the entered zipcode, or if there is no corresponding 3-digit zip area, zipCheck beeps and returns a null string instead of a state abbreviation.